{layout name="common/layout" /}

<div class="dislpayArrow hidden-xs"><a class="pngfix" href="javascript:void(0);" onClick="displaynavbar(this)"></a></div>
<style>
    .main_area{
        width:100%;
        height:100%;
        position: relative;
        bottom:0;
        overflow: auto;
    }
    .post_form{
        box-sizing:unset;
        padding: 15px 50px;
        margin: -10px auto;
    }
    .red_must{
        color: red;
        padding-right: 5px;
    }
    .sub_title{
        position: relative;
        float: left;
        width: 120px;
    }
    .editer{
        margin-left: 0px;
    }
    .sub_body{

    }
    /*按钮*/
    .btn_area{
        width: 45%;
        position: relative;
        margin: 40px auto;
    }
    input {
        font-size: 14px;
        color: #222;
        margin: -5px 0 0 10px;
        outline: none;
        border: none;
    }
</style>
<div class="Hui-article-box">
    <div class="Hui-article" style="top:0px;">
        <h3 class="showlist_title">优惠券>优惠券详情</h3>
    <div class="main_area">
        <div style="position: relative;width:100%;margin-left: 60px;margin-top: 40px;">
            <div class="lab cl">
                <div class="lab-l">
                    <span class="span"><label class="red_must">&nbsp;</label>类型</span>
                </div>
                <div class="lab-r" style="border:0;margin-top: 10px;">
                    <input class="coupon_id" type="hidden" value="{$couponinfo['id']}" />
                    <label>{if condition="$couponinfo['type'] eq '1'"}红包{else/}满减券{/if}&nbsp;&nbsp;(优惠券编号{$couponinfo['coupon_no']})</label>
                    <input type="submit" class="btn user_detail" style="margin-left: 30px;width:150px;" value="查看用户领取详情"/>
                </div>
            </div>
            <div class="lab cl">
                <div class="lab-l">
                    <span class="span"><label class="red_must">&nbsp;</label>创建者</span>
                </div>
                <div class="lab-r" style="border:0;margin-top: 10px;">
                    <label>{if condition="$couponinfo['store_id'] eq '0'"}平台{else/}店铺--{$couponinfo['store_name']}{/if}&nbsp;&nbsp;({$couponinfo['create_time']})</label>
                </div>
            </div>
            <!--
            <div class="lab cl">
                <div class="lab-l">
                    <span class="span"><label class="red_must">&nbsp;</label>标题</span>
                </div>
                <div class="lab-r" style="border:0;margin-top: 10px;">
                    <label>{$couponinfo['coupon_name']}</label>
                </div>
            </div>
            -->
            <div class="lab cl">
                <div class="lab-l">
                    <span class="span"><label class="red_must">&nbsp;</label>使用范围</span>
                </div>
                <div class="lab-r" style="border:0;margin-top: 10px;">
                    <label>{if condition="$couponinfo['use_range'] eq '1'"}平台{else/}全店通用{/if}</label>
                </div>
            </div>
            <div class="lab cl">
                <div class="lab-l">
                    <span class="span"><label class="red_must">&nbsp;</label>发放总量</span>
                </div>
                <div class="lab-r" style="border:0;margin-top: 10px;">
                    <label>{$couponinfo['number']}张</label>
                </div>
            </div>
            <div class="lab cl">
                <div class="lab-l">
                    <span class="span"><label class="red_must">&nbsp;</label>面值</span>
                </div>
                <div class="lab-r" style="border:0;margin-top: 10px;">
                    <label>{$couponinfo['amount']}元</label>
                </div>
            </div>
            <div class="lab cl">
                <div class="lab-l">
                    <span class="span"><label class="red_must">&nbsp;</label>使用条件</span>
                </div>
                <div class="lab-r" style="border:0;margin-top: 10px;">
                    <label>{if condition="$couponinfo['use_minimal_amount'] gt '0'"}满{$couponinfo['use_minimal_amount']}元{else/}无限制{/if}</label>
                </div>
            </div>
            <div class="lab cl">
                <div class="lab-l">
                    <span class="span"><label class="red_must">&nbsp;</label>每人限领</span>
                </div>
                <div class="lab-r" style="border:0;margin-top: 10px;">
                    <label>{$couponinfo['user_number']}张</label>
                </div>
            </div>
            <div class="lab cl">
                <div class="lab-l">
                    <span class="span"><label class="red_must">&nbsp;</label>生效时间</span>
                </div>
                <div class="lab-r" style="border:0;margin-top: 10px;">
                    <label>{if condition="$couponinfo['effect_type'] eq '0'"}按领取日期{else/}按固定时间:从{$couponinfo['effect_time']}起{/if}</label>
                </div>
            </div>
            <div class="lab cl">
                <div class="lab-l">
                    <span class="span"><label class="red_must">&nbsp;</label>优惠券生效天数</span>
                </div>
                <div class="lab-r" style="border:0;margin-top: 10px;">
                    <label>{$couponinfo['effect_days']}天(从生效时间开始往后计算)</label>
                </div>
            </div>
            <!--
            <div class="lab cl">
                <div class="lab-l">
                    <span class="span"><label class="red_must">&nbsp;</label>活动</span>
                </div>
                <div class="lab-r" style="border:0;margin-top: 10px;">
                    <label>{if condition="$couponinfo['activity_id'] eq '0'"}无{else/}{$couponinfo['activity_name']}{/if}</label>
                </div>
            </div>
            -->
            <div class="lab cl">
                <div class="lab-l">
                    <span class="span"><label class="red_must">&nbsp;</label>发放起止日期</span>
                </div>
                <div class="lab-r" style="border:0;margin-top: 10px;">
                    <label>{$couponinfo['activity_start_time']}至{$couponinfo['activity_end_time']}</label>
                </div>
            </div>
            <div class="lab cl">
                <div class="lab-l">
                    <span class="span"><label class="red_must">&nbsp;</label>规则说明链接</span>
                </div>
                <div class="lab-r" style="border:0;margin-top: 10px;">
                    <label>{if condition="$couponinfo['rule_intro_url'] eq ''"}暂无规则链接{else/}{$couponinfo['rule_intro_url']}{/if}</label>
                </div>
            </div>
            <div class="lab cl">
                <div class="lab-l">
                    <span class="span"><label class="red_must">&nbsp;</label>状态</span>
                </div>
                <div class="lab-r" style="border:0;margin-top: 10px;">
                    <label>{if condition="$couponinfo['status'] eq '1'"}有效{else/}失效中{/if}</label>
                </div>
            </div>
            <div  class="div-box btn_area">
                <input type="submit" class="btn back_btn" style="margin-left: 30px;" value="返回"/>
            </div>
        </div>
    </div>
</div>
</div>
<script type="text/javascript">
    /**
     * 按钮点击
     */
    $(".user_detail").click(function(){
        window.location.href ="{:url('coupon/listUserCoupon')}?id="+$(".coupon_id").val()+"&page={$page}";
    });

    $(".add_btn").click(function(){
        window.location.href ="{:url('coupon/updateCoupon')}?id="+$(".coupon_id").val()+"&page={$page}";
    });

    $(".back_btn").click(function(){
        window.location.href ="{:url('coupon/listCoupon')}?page={$page}";
    });
</script>